package com.gamecat.basetest

import android.os.Bundle
import android.support.v7.app.AppCompatActivity
import android.util.Log
import android.widget.TextView
import com.alibaba.fastjson.TypeReference
import com.bldby.baselibrary.core.ui.baseactivity.BaseBActivity
import com.squareup.moshi.Moshi
import com.squareup.moshi.Types


class MainActivity : BaseBActivity() {
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContentView(R.layout.activity_main)


        val findViewById = findViewById<TextView>(R.id.xx)

        val moshi = Moshi.Builder()
            .build()
        findViewById.setOnClickListener {
            val arrayList = ArrayList<String>()
            arrayList.add("...1.")
            arrayList.add("..2..")
            arrayList.add("..2s..")
            arrayList.add("..2d..")
            arrayList.add("..2.v.")
            val value = object : TypeReference<List<Xg>>() {}
            val newParameterizedType = Types.newParameterizedType(
                List::class.java,
                Xg::class.java
            )
            Log.e("TAG", "onCreate: " + value + newParameterizedType)
        }
    }

    override fun bindIngView() {
        TODO("Not yet implemented")
    }

    override fun initView() {
        TODO("Not yet implemented")
    }

    override fun loadData() {
        TODO("Not yet implemented")
    }

    override fun initListener() {
        TODO("Not yet implemented")
    }
}